<!DOCTYPE html>
<html>
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0"/>
        <meta name="format-detection" content="telephone=no" />
        <title>公司介绍</title>
        <link rel="stylesheet" type="text/css" href="../css/aui.css" />
        <link rel="stylesheet" type="text/css" href="../css/common.css" />
        <style>
        
        html, body {
            height: 100%;
            margin: 0px;
            padding: 0px;
            overflow: hidden;
            -webkit-touch-callout: none;
            -webkit-user-select: none;
        }

        .aui-icon-more{
            color:#000 !important;
        }
        footer input[type="text"]{
            margin-bottom: 0 !important;
            padding:0;
            height: 36px;
        }
        footer .aui-bar-tab{
            margin-bottom: 0;
            line-height: 55px;
            padding:0 10px;
        } 
        .divChat{
            padding-right:8px;
        }
        </style>
    </head>
    <body>
        <header class="aui-bar aui-bar-nav aui-border-b">
            <div class="aui-pull-left aui-iconfont aui-icon-left icon-left-coler" tapmode onclick="closeWin()"></div>
            <div class="aui-title">
                Aileen纱纺有限公司
            </div>
             <i class="aui-iconfont aui-icon-more  aui-pull-right" tapmode onclick="popHome()"></i>
        </header>
        <footer class="aui-nav" id="aui-footer">
            <ul class="aui-bar-tab">
                <li class="" id="" tapmode >
                    <div class="aui-pull-left aui-col-xs-10 divChat">
                        <input type="text" class="inputChat" name="">
                    </div>
                    <div class="aui-pull-left aui-col-xs-1">
                         <i class="aui-iconfont aui-icon-emoji"></i>
                    </div>
                    <div class="aui-pull-left aui-col-xs-1">
                         <i class="aui-iconfont aui-icon-add"></i>
                    </div>
                </li>
                
            </ul>
        </footer>
    </body>
    <script type="text/javascript" src="../script/api.js"></script>
    <script type="text/javascript" src="../script/common.js"></script>
    <script type="text/javascript" src="../script/jquery-1.11.3.js"></script>
    <script type="text/javascript" src="../script/mui.js"></script>
    <script type="text/javascript">
        apiready = function() {
            api.parseTapmode();
            var mobile = api.pageParam.mobile;
            var header = $api.dom('header');
            var footer = $api.dom('footer');
            //$api.fixStatusBar(header);
            api.setStatusBarStyle({
                  style : 'light'
            });
            var header_h = $api.offset(header).h;
            var footer_h = $api.offset(footer).h;
            var body_h = $api.offset($api.dom('body')).h - header_h-footer_h;
            api.openFrame({
                name : 'chat_frm2',
                url : 'chat_frm2.html',
                rect : {
                    x : 0,
                    y : header_h,
                    w : 'auto',
                    h : body_h
                },
                pageParam : {
                    mobile : mobile
                },
                bounces : false,
                vScrollBarEnabled : false,
                hScrollBarEnabled : false
            });
        }
        $(".inputChat").focus(function(){
            api.execScript({
                frameName:"chat_frm2",
                script:"setHeight()"
            })
        })
        // mui遮罩
        var mask;
        // 显示遮罩
        function popHome(){
            mask = mui.createMask(hidePicker);
            mask.show();
            //跨域执行子frame的显示mask
            api.execScript({
                frameName:"chat_frm2",
                script:"showMask()"
            })
        }
        // 关闭遮罩
        function hidePicker(){
            //跨域执行子frame的关闭mask
            api.execScript({
                frameName:"chat_frm2",
                script:"hideFrmMask()"
            })
        }
        //接收子frm执行的关闭遮罩
        function closeWinMask(){
            mask.myclose();
            //hidePicker();
        }
    </script>
</html>
